import { LLMModel } from "./llmModel";
import { DouBaoEmbeddings } from "./doubao_embeddings";

const key = "3d55e44d-c379-4ec0-83cc-6d8993d297da";
const base_url = "https://ark.cn-beijing.volces.com/api/v3/chat/completions";

export class LLMProvider {
    static current = new LLMProvider();
    get ZiJieDeepSeekV3() {
        return new LLMModel({
            model: "ep-20250522145207-nwwf5",
            key,
            url: base_url,
            maxTokens: 1024 * 15
        });
    }

    get ZiJieDeepSeekR1() {
        return new LLMModel({
            model: "ep-20250814150711-sbngd",
            key,
            url: base_url,
            maxTokens: 1024 * 16,
            thinking: "enabled"
        });
    }

    get ZiJieDouBaoSeed16() {
        return new LLMModel({
            model: "ep-20250814112718-p8vxn",
            key,
            url: base_url,
            maxTokens: 1024 * 20,
            thinking: "enabled"
        });
    }

    get DoubaoSeed16Vision() {
        return new LLMModel({
            model: "ep-20250912200613-7g79m",
            key,
            url: base_url,
        });
    }

    get DoubaoSeedream30() {
        return new LLMModel({
            model: "ep-20250819103642-pzc42",
            key,
            url: "https://ark.cn-beijing.volces.com/api/v3/images/generations",
            seed: -1,
            guidance_scale: 2.5,
            size: "512x512",
            isImageModel: true,
        });
    }

    get DoubaoSeedream30Edit() {
        return new LLMModel({
            model: "ep-20250923191226-dx85p",
            key,
            url: "https://ark.cn-beijing.volces.com/api/v3/images/generations",
            seed: -1,
            guidance_scale: 2.5,
            size: "512x512",
            isImageModel: true,
        });
    }
    
    /**
     * 豆包文生图模型
     *
     * @readonly
     * @memberof LLMProvider
     */
    get DoubaoSeedream40() {
        return new LLMModel({
            model: "ep-20250912200506-sw57x",
            key,
            url: "https://ark.cn-beijing.volces.com/api/v3/images/generations",
            seed: -1,
            // guidance_scale: 2.5,
            size: "512x512",
            isImageModel: true,
            
        });
    }

    get DouBaoEmbeddingLarge() {
        return new DouBaoEmbeddings({
            key: "3d55e44d-c379-4ec0-83cc-6d8993d297da",
            url: "https://ark.cn-beijing.volces.com/api/v3/embeddings",
            model: "ep-20250208133412-7rthf"
        });
    }
}